package com.wty.cmims.service;

import com.wty.cmims.pojo.ResponseResult;
import com.wty.cmims.pojo.User;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.Map;

/**
* @author wty
* @description 针对表【user】的数据库操作Service
* @createDate 2024-10-01 18:06:53
*/
public interface UserService extends IService<User> {

    /**
     * 用户注册
     * @param name
     * @param account
     * @param password
     * @param role
     * @return
     */
    ResponseResult<Map<String, Object>> userRegister(String name, String account, String phone, String password, Integer role);

    ResponseResult<Map<String, Object>> userLogin(String account, String password);

    ResponseResult<User> userUpdate(User user);

    ResponseResult<Void> updatePassword(String account, String oldPassword, String newPassword);
}
